<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>径向渐变</title>
    <style>
        #grad1{
            height: 150px;
            width: 200px;
            background-image: radial-gradient(red, yellow, green);
            float: left;
            margin-left: 15px;
        }
        #grad2{
            height: 150px;
            width: 200px;
            background-image: radial-gradient(red 5%, yellow 15%, green 60%);
            float: left;
            margin-left: 15px;
        }
        /*设置形状：圆形*/
        #grad3{
            height: 150px;
            width: 200px;
            background-image: radial-gradient(circle,red, yellow, green);
            float: left;
            margin-left: 15px;
        }
        /*重复径向渐变repeating-radial-gradient() 函数*/
        #grad4{
            height: 150px;
            width: 200px;
            background-image: repeating-radial-gradient(red , yellow 10%, green 15%);
            float: left;
            margin-left: 15px;
        }
    </style>
</head>
<body>
<div id="grad1"></div>
<div id="grad2"></div>
<div id="grad3"></div>
<div id="grad4"></div>
</body>
</html>